package com.xy.designPatterns.chainOfResponsibility;

public class AdHandler extends AbstractArticleHandler {

    @Override
    protected boolean canHandle(Article article) {
        return article.getContent().contains("广告");
    }

    @Override
    protected void doHandle(Article article) {
        // 检测到广告，转入广告处理流程
    }
}
